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!
|
|
How to generate ID for a table without using "SLX_DBIDs" Sp
Posted: 11 Sep 07 5:49 AM
|
Hi All!
Can anyone suggest me how I can generate IDs for a table to insert records into it without using SLX_DBIDs.
I'm particular about not using SLX_DBIDs because I'm using an SQLOLEDB.1 and not SLX OleDB.
TIA. CGK. |
|
|
| |
| |
|
Re: How to generate ID for a table without using "SLX_DBIDs" Sp
Posted: 12 Sep 07 12:31 AM
|
Take a look at this article on the site, it is a good guide to learn how to generate IDs for SalesLogix.
It also contains an example of using the OleDb with SLX. Just remember that you have to at least have the SLX OLEDB provider installed on the machine where this code is being executed (your dev box), and also, you can use a .UDL file to create the connection to SLX, then open it on notepad and extract the connection string.
C# Example from the Article:
public string NewID(string table) { using (OleDbConnection conn = new OleDbConnection(SlxConnectionString)) { conn.Open(); using (OleDbCommand cmd = new OleDbCommand(string.Format("slx_dbids('{0}', 1)", table), conn)) { return cmd.ExecuteScalar().ToString(); } } } |
|
|
|
Re: How to generate ID for a table without using "SLX_DBIDs" Sp
Posted: 12 Sep 07 8:21 AM
|
Well , i have heard a lotta ppl sayinig dotnet and saleslogix...
For accessing a slx db, nothing has changed in terms of how to access it.sure we can do this thru vbscript, vb , and all dot net langs.But all of those are just langs which HAS to use the SLXOLEDB provider to get in.Using the provider is the key ;nothing else is.... |
|
|
|