
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎12-19-2011 03:36 PM
They all have the same purchase date, warranty and cost (which we are using custom field 1 for).
Rather than manually enter this information on each laptop, is there a way to run an SQL query in the Lansweeper configuration app?
Any help greatly appreciated!
- Labels:
-
Archive

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-03-2012 11:40 AM

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-03-2012 11:16 AM

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎12-20-2011 03:58 PM
I have many bar code entries I need to input, it is a four digit number that increments by 1 each time. e.g.
UPDATE tblCompCustom
SET BarCode= '3001'
FROM tblCompCustom INNER JOIN
tblComputers ON tblCompCustom.Computername = tblComputers.Computername
WHERE (tblComputers.Computer LIKE 'R21-STN01')
Then the next one ...
UPDATE tblCompCustom
SET BarCode= '3002'
FROM tblCompCustom INNER JOIN
tblComputers ON tblCompCustom.Computername = tblComputers.Computername
WHERE (tblComputers.Computer LIKE 'R21-STN02')
Etc. Is there a way of entering this all in one go in one SQL statement?

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎12-20-2011 02:44 PM
I was doing this the long way by entering some dummie information in the Custom field1 then running the previous query, but this way saves me a lot of time. Thanks again

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎12-20-2011 02:40 PM
INSERT INTO tblCompCustom (Computername)
SELECT Computername
FROM tblComputers
WHERE (Computername NOT IN (SELECT Computername FROM tblCompCustom AS tblCompCustom_1))
GO
UPDATE tblCompCustom
SET Custom1 = '£259.00'
FROM tblCompCustom INNER JOIN
tblComputers ON tblCompCustom.Computername = tblComputers.Computername
WHERE (tblComputers.Computer LIKE 'R21-STN%')

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎12-20-2011 02:09 PM
The SQL statment says "The command completed successfully" but when I check the entry in the browser the field is still blank.
UPDATE tblCompCustom
SET Custom1 = '£259.00'
FROM tblCompCustom INNER JOIN
tblComputers ON tblCompCustom.Computername = tblComputers.Computername
WHERE (tblComputers.Computer LIKE 'R21-STN%')
Basically we have a numbre of machines called R21-STN01, R21-STN02 etc.etc.
Am I missing something?

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎12-20-2011 10:50 AM
Change purchase date for computers whose name starts with "English":
UPDATE tblCompCustom
SET PurchaseDate = 'YourInfo'
FROM tblCompCustom INNER JOIN
tblComputers ON tblCompCustom.Computername = tblComputers.Computername
WHERE (tblComputers.Computer LIKE 'English%')
Change warranty date for computers whose name starts with "English":
UPDATE tblCompCustom
SET WarrantyDate = 'YourInfo'
FROM tblCompCustom INNER JOIN
tblComputers ON tblCompCustom.Computername = tblComputers.Computername
WHERE (tblComputers.Computer LIKE 'English%')

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎12-20-2011 10:45 AM
Is there any way of doing something like this with purchase date and warranty date?

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎12-19-2011 06:22 PM
UPDATE tblCompCustom
SET Custom1 = 'YourInfo'
FROM tblCompCustom INNER JOIN
tblComputers ON tblCompCustom.Computername = tblComputers.Computername
WHERE (tblComputers.Computer LIKE 'English%')
