The Forums on slxdeveloper.com are now retired. The forum archive will remain available for the time being. Thank you for your participation on slxdeveloper.com!
|
|
Add / Update Contact record
Posted: 15 Aug 06 3:15 AM
|
fiogf49gjkf0d I have an external app that has a SQL database. Any time someone adds a record into that extrenal database I would like to update or add a new contact record into SLX. I have heard that the best way to do this is to create a trigger that would launch an external app. Reading into the documentations I should not use the COM object because there has to be an open client. What would be the best way to do this. I would like this to be sync compatible but it is not really needed.
On a second question. Do you have to be a partner to get into the SLXDN?
Thanks Matt |
|
|
|
Re: Add / Update Contact record
Posted: 15 Aug 06 12:59 PM
|
fiogf49gjkf0d Using triggers is more accurate, but also more problematic. I would suggest building a windows service that scans the other db and creates any missing entries in the SLX db. Have it run on some interval. This way it keeps the two in-sync, not real time, but likely close enough - within 5 mins or so (depending on the interval you use). This is the safest route to go IMO. I am sure the other system has some sort of record identifier as well, just make sure you import that with the contact/account data so you can easily identify if the record has already been added to SLX.
As far as the SLXDN, that is now gone (doesn't exist any more). I just keep forgetting to remove it from the resources area on this site. |
|
|
|
Re: Add / Update Contact record
Posted: 15 Aug 06 1:59 PM
|
fiogf49gjkf0d To do the service should I use the OLE DB Provider? If so where can I find some documentation on it? |
|
|
| |
| |
| |
|
Re: Add / Update Contact record
Posted: 15 Aug 06 4:01 PM
|
fiogf49gjkf0d No. That has a special purpose specific to making a record appear on the "What's New" list on remote databases.
For inserting data into SLX, there are not special procedures to use. You need to establish a connection (using ADO.NET/ADO/etc - or use something like MS DTS), and write to the appropriate tables. For accounts and contacts I outlined the tables to write to in a post here: http://www.slxdeveloper.com/forum.aspx?forumid=6000&postid=2570#2570 |
|
|
|
Re: Add / Update Contact record
Posted: 15 Aug 06 4:05 PM
|
fiogf49gjkf0d Thank you SO much. If I'm just writing data directly to the tables wouldn't I just use SQL triggers? Or when using the ADO.NET does SLX have something that monitors it and adds it to make it sync capable? |
|
|
|
Re: Add / Update Contact record
Posted: 15 Aug 06 4:07 PM
|
fiogf49gjkf0d The important part to understand is the connection. The connection must use the SLX provider. One of the articles I linked to above is one about the SLX connection string. The connection must use this so it goes throug the SLX provider. If you use triggers then the inserts are not going through the provider and nothing will sync etc. |
|
|
|
Re: Add / Update Contact record
Posted: 16 Aug 06 1:22 PM
|
fiogf49gjkf0d One thing to note is the RWPassword isn't necessary if you have a username/password from SalesLogix. It was necessary in 6.1 I believe but some service pack or 6.2 removed the need to have it. It's mainly there so you don't hardcode your admin password somewhere people can find it I'd think. |
|
|
|
Re: Add / Update Contact record
Posted: 16 Aug 06 1:32 PM
|
fiogf49gjkf0d Actually...
A SLX user name and password is always required to make a connection via the SLX provider. The RWPassword is a way that an administrator can prevent external access to SLX via connections through the provider.
For example, if I have some SLX users that are also able to write scripts, I can set an RW Password to prevent them from accessing SLX via their scripts (because they wouldn't know the RW password).
Either way, whether you set a RW Password or not, you still need a valid SLX username & password to log in via the provider. If an RW password has been set then I also need that as well in order to read or write from the connection.
So it is "in addition to", not "instead of".
Make sense?
Personally, I've never thought the idea of the RW password was any good, I would prefer that they did away with that altogether. There's so many ways around it that it makes it just useless anyway.
Edit
Also, to clarify, if the RW password is blank for the connection then you can omit it completely from the connection string (which is how this probably gets confused for so many in the first place) |
|
|
|
Re: Add / Update Contact record
Posted: 16 Aug 06 1:46 PM
|
fiogf49gjkf0d Ahh that makes perfect sense. I could have probably verified it before I said something but it's good to know this is necessary.
I have a blank RWPass for reading and one set for writing, so I omit it from the connection string most of the time. It is a little confusing because it seems necessary when in actuality it usually isn't. A resourceful user can pretty much do anything they want with SLX data so I agree that RWPass doesn't really keep everything secure, it just adds a layer of protection to the provider for people that want it. I think it's an okay thing to have when it makes sense but I've rarely found a need for it. |
|
|
|