Ask a Question related to ASP Database, Design and Development.
-
DblPrimaryKey on SQL to match Access?
Is it possilble or advisable to implement a double primary key on an sql
server table to match an Access Table....
As I understand it, I could create a 2 "Int" datatypes on the two fields
with "Primary" and Seed enabled....
Thanks
Jason
Guest
-
Can't access font style to match rest of page
Hello: I'm trying to create text in a table next to an image. The text on the page is Arial 10, Style: Normal. But when I add new text it... -
Query to match date -- ODBD -- Access database
I am running CF5, and using ODBC to query an Access 2002 database. I think these are the parts of my program that illustrate the problem: <cfset... -
Why is this not a match?
Hello All, I am unable to find out why is this not matching: I do have a file where the second line contains: Summary Log (generated: Tue... -
pattern match
Where can I find infi or doc on "pattern match" used within WHERE clause (mysql). As I need to matche with PHP variables I'd prfer something... -
[PHP] trying to match the front and end...
On 08 August 2003 15:39, Dan Joseph wrote: $middlenum = preg_replace("/^${this->start_num}(.*)${this->end_num}$/", '$1', $this->ach_acct_num); ... -
Re: DblPrimaryKey on SQL to match Access?
Hold on...it appears I can highlight the two fields simultaneously and
insitute a double-primary key to match the access table...will do unless
tells me this is a dangerous path.
Thanks
Jason
<jason@catamaranco.com> wrote in message
news:OohmEDadEHA.212@TK2MSFTNGP12.phx.gbl...> Is it possilble or advisable to implement a double primary key on an sql
> server table to match an Access Table....
>
> As I understand it, I could create a 2 "Int" datatypes on the two fields
> with "Primary" and Seed enabled....
>
> Thanks
> Jason
>
>
Guest
-
Aaron [SQL Server MVP] #3
Re: DblPrimaryKey on SQL to match Access?
> As I understand it, I could create a 2 "Int" datatypes on the two fields
You want two separate autonumber columns? Why?> with "Primary" and Seed enabled....
Anyway, yes, you can create a primary key in SQL Server with multiple
columns.
CREATE TABLE dbo.OrderDetails
(
OrderNumber INT, -- FK
ProductID INT, -- FK
-- other columns, e.g. quantity --
PRIMARY KEY(OrderNumber, ProductID)
)
I strongly recommend learning the technology rather than poking around the
wizards and guis and stumbling across things that just happen to work.
--
[url]http://www.aspfaq.com/[/url]
(Reverse address to reply.)
Aaron [SQL Server MVP] Guest
-
Re: DblPrimaryKey on SQL to match Access?
Actually, I miscued...I needed two 'primary' key columns based on a previous
access table....I used the GUI to create this double-key....but I see now
that experienced programmers
are creating the SPs and tables on the fly as you have done below....
At the moment I am just trying to get an existing access application running
on sql server....I don't have the time to do indepth analysis...I plan to
adjust the data types
where necessary and convert one query into an SP and then adjust my .ASP
scripts to correctly call the SP and interrogat the converted tables...
Thanks
Jason
"Aaron [SQL Server MVP]" <ten.xoc@dnartreb.noraa> wrote in message
news:%23kCx4jadEHA.3916@TK2MSFTNGP11.phx.gbl...>> > As I understand it, I could create a 2 "Int" datatypes on the two fields
> > with "Primary" and Seed enabled....
> You want two separate autonumber columns? Why?
>
> Anyway, yes, you can create a primary key in SQL Server with multiple
> columns.
>
> CREATE TABLE dbo.OrderDetails
> (
> OrderNumber INT, -- FK
> ProductID INT, -- FK
> -- other columns, e.g. quantity --
> PRIMARY KEY(OrderNumber, ProductID)
> )
>
> I strongly recommend learning the technology rather than poking around the
> wizards and guis and stumbling across things that just happen to work.
>
> --
> [url]http://www.aspfaq.com/[/url]
> (Reverse address to reply.)
>
>
Guest



Reply With Quote

