?
Solved

Urgent:Generating a Database from SQL Script

Posted on 2004-10-31
5
Medium Priority
?
308 Views
Last Modified: 2008-02-01
Hey experts,

I have a database in the form of an SQL script (its data & meta-data), and I want to generate a database on Access using this script......any help??
0
Comment
Question by:mte01
  • 3
  • 2
5 Comments
 
LVL 3

Author Comment

by:mte01
ID: 12461053
Can anyone help...this question is a bit urgent....
0
 
LVL 18

Expert Comment

by:Data-Man
ID: 12465087
What does the script look like?

Mike
0
 
LVL 3

Author Comment

by:mte01
ID: 12474608
Something like that:



/****** Object:  Table [dbo].[UPR10300]    Script Date: 07/30/2004 4:16:04 PM ******/
if exists (select * from dbo.sysobjects where id = object_id(N'[dbo].[UPR10300]') and OBJECTPROPERTY(id, N'IsUserTable') = 1)
drop table [dbo].[UPR10300]
GO

/****** Object:  Table [dbo].[UPR10304]    Script Date: 07/30/2004 4:16:04 PM ******/
if exists (select * from dbo.sysobjects where id = object_id(N'[dbo].[UPR10304]') and OBJECTPROPERTY(id, N'IsUserTable') = 1)
drop table [dbo].[UPR10304]
GO

/****** Object:  Table [dbo].[UPR41105]    Script Date: 07/30/2004 4:16:04 PM ******/
if exists (select * from dbo.sysobjects where id = object_id(N'[dbo].[UPR41105]') and OBJECTPROPERTY(id, N'IsUserTable') = 1)
drop table [dbo].[UPR41105]
GO

/****** Object:  Table [dbo].[UPR41300]    Script Date: 07/30/2004 4:16:04 PM ******/
if exists (select * from dbo.sysobjects where id = object_id(N'[dbo].[UPR41300]') and OBJECTPROPERTY(id, N'IsUserTable') = 1)
drop table [dbo].[UPR41300]
GO

/****** Object:  Table [dbo].[UPR41301]    Script Date: 07/30/2004 4:16:04 PM ******/
if exists (select * from dbo.sysobjects where id = object_id(N'[dbo].[UPR41301]') and OBJECTPROPERTY(id, N'IsUserTable') = 1)
drop table [dbo].[UPR41301]
GO

/****** Object:  Table [dbo].[UPR41302]    Script Date: 07/30/2004 4:16:04 PM ******/
if exists (select * from dbo.sysobjects where id = object_id(N'[dbo].[UPR41302]') and OBJECTPROPERTY(id, N'IsUserTable') = 1)
drop table [dbo].[UPR41302]
GO

/****** Object:  Table [dbo].[UPR41303]    Script Date: 07/30/2004 4:16:04 PM ******/
if exists (select * from dbo.sysobjects where id = object_id(N'[dbo].[UPR41303]') and OBJECTPROPERTY(id, N'IsUserTable') = 1)
drop table [dbo].[UPR41303]
GO

/****** Object:  Table [dbo].[UPR41600]    Script Date: 07/30/2004 4:16:04 PM ******/
if exists (select * from dbo.sysobjects where id = object_id(N'[dbo].[UPR41600]') and OBJECTPROPERTY(id, N'IsUserTable') = 1)
drop table [dbo].[UPR41600]
GO

/****** Object:  Table [dbo].[UPR10300]    Script Date: 07/30/2004 4:16:13 PM ******/
CREATE TABLE [dbo].[UPR10300] (
      [CMPANYID] [smallint] NOT NULL ,
      [USERID] [char] (15) COLLATE Latin1_General_BIN NOT NULL ,
      [PYRLACTV] [char] (7) COLLATE Latin1_General_BIN NOT NULL ,
      [DEX_ROW_ID] [int] IDENTITY (1, 1) NOT NULL
) ON [PRIMARY]
GO

/****** Object:  Table [dbo].[UPR10304]    Script Date: 07/30/2004 4:16:15 PM ******/
CREATE TABLE [dbo].[UPR10304] (
      [CMPANYID] [smallint] NOT NULL ,
      [BACHNUMB] [char] (15) COLLATE Latin1_General_BIN NOT NULL ,
      [UPRBCHOR] [smallint] NOT NULL ,
      [USERID] [char] (15) COLLATE Latin1_General_BIN NOT NULL ,
      [UPRBCHST] [smallint] NOT NULL ,
      [DEX_ROW_ID] [int] IDENTITY (1, 1) NOT NULL
) ON [PRIMARY]
GO

/****** Object:  Table [dbo].[UPR41105]    Script Date: 07/30/2004 4:16:16 PM ******/
CREATE TABLE [dbo].[UPR41105] (
      [CCode] [char] (7) COLLATE Latin1_General_BIN NOT NULL ,
      [CCodeDesc] [char] (31) COLLATE Latin1_General_BIN NOT NULL ,
      [DEX_ROW_ID] [int] IDENTITY (1, 1) NOT NULL
) ON [PRIMARY]
GO

/****** Object:  Table [dbo].[UPR41300]    Script Date: 07/30/2004 4:16:17 PM ******/
CREATE TABLE [dbo].[UPR41300] (
      [TAXCODE] [char] (7) COLLATE Latin1_General_BIN NOT NULL ,
      [DSCRIPTN] [char] (31) COLLATE Latin1_General_BIN NOT NULL ,
      [TXCALCTN_1] [smallint] NOT NULL ,
      [TXCALCTN_2] [smallint] NOT NULL ,
      [TXCALCTN_3] [smallint] NOT NULL ,
      [TXCALCTN_4] [smallint] NOT NULL ,
      [TXCALCTN_5] [smallint] NOT NULL ,
      [TXCALCTN_6] [smallint] NOT NULL ,
      [TXCALCTN_7] [smallint] NOT NULL ,
      [TXCALCTN_8] [smallint] NOT NULL ,
      [TXCALCTN_9] [smallint] NOT NULL ,
      [TXCALCTN_10] [smallint] NOT NULL ,
      [ESTDEDTN] [numeric](19, 5) NOT NULL ,
      [DEPEXMPT] [numeric](19, 5) NOT NULL ,
      [MXEICPMT] [numeric](19, 5) NOT NULL ,
      [EXWGLIMT] [numeric](19, 5) NOT NULL ,
      [EXTXRATE] [int] NOT NULL ,
      [DEX_ROW_ID] [int] IDENTITY (1, 1) NOT NULL
) ON [PRIMARY]
GO

/****** Object:  Table [dbo].[UPR41301]    Script Date: 07/30/2004 4:16:17 PM ******/
CREATE TABLE [dbo].[UPR41301] (
      [TAXCODE] [char] (7) COLLATE Latin1_General_BIN NOT NULL ,
      [TXFLGSTS] [char] (7) COLLATE Latin1_General_BIN NOT NULL ,
      [STSDESCR] [char] (31) COLLATE Latin1_General_BIN NOT NULL ,
      [LINCLIM] [numeric](19, 5) NOT NULL ,
      [PRSEXAMT] [numeric](19, 5) NOT NULL ,
      [INCPSNEX] [tinyint] NOT NULL ,
      [INCADALW] [tinyint] NOT NULL ,
      [INCLDEPN] [tinyint] NOT NULL ,
      [FDTXPRCT] [int] NOT NULL ,
      [FEDTXMAX] [numeric](19, 5) NOT NULL ,
      [FICATXPT] [int] NOT NULL ,
      [FICATXMN] [numeric](19, 5) NOT NULL ,
      [FLATAXRT] [int] NOT NULL ,
      [STDDMTHD] [smallint] NOT NULL ,
      [STDDPCNT] [int] NOT NULL ,
      [STDDEDAM] [numeric](19, 5) NOT NULL ,
      [STDEDMIN] [numeric](19, 5) NOT NULL ,
      [STDEDMAX] [numeric](19, 5) NOT NULL ,
      [SPCLEXAM] [numeric](19, 5) NOT NULL ,
      [SPCLSDED] [numeric](19, 5) NOT NULL ,
      [SPCLTXRT] [int] NOT NULL ,
      [DEX_ROW_ID] [int] IDENTITY (1, 1) NOT NULL
) ON [PRIMARY]
GO

/****** Object:  Table [dbo].[UPR41302]    Script Date: 07/30/2004 4:16:18 PM ******/
CREATE TABLE [dbo].[UPR41302] (
      [TAXCODE] [char] (7) COLLATE Latin1_General_BIN NOT NULL ,
      [TXFLGSTS] [char] (7) COLLATE Latin1_General_BIN NOT NULL ,
      [TXTBLTYP] [smallint] NOT NULL ,
      [TXTBLSEQ] [smallint] NOT NULL ,
      [TXBRULMT] [numeric](19, 5) NOT NULL ,
      [TXBRKTAM] [numeric](19, 5) NOT NULL ,
      [RXBRKTRT] [int] NOT NULL ,
      [TXBREXWG] [numeric](19, 5) NOT NULL ,
      [DEX_ROW_ID] [int] IDENTITY (1, 1) NOT NULL
) ON [PRIMARY]
GO

................etc


0
 
LVL 18

Accepted Solution

by:
Data-Man earned 1500 total points
ID: 12474867
I don't think you can use the script in Access without modifying it.
If you have access to SQL Server, you could link the tables from SQL Server and then copy possibly copy and paste them as Access tables.

Mike
0
 
LVL 3

Author Comment

by:mte01
ID: 12474899
Ahaa.....okk...thank you.....my problem has been solved right now because I re-installed MSSQL Server
0

Featured Post

The new generation of project management tools

With monday.com’s project management tool, you can see what everyone on your team is working in a single glance. Its intuitive dashboards are customizable, so you can create systems that work for you.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

If you need a simple but flexible process for maintaining an audit trail of who created, edited, or deleted data from a table, or multiple tables, and you can do all of your work from within a form, this simple Audit Log will work for you.
Implementing simple internal controls in the Microsoft Access application.
In Microsoft Access, learn how to use Dlookup and other domain aggregate functions and one method of specifying a string value within a string. Specify the first argument, which is the expression to be returned: Specify the second argument, which …
With Microsoft Access, learn how to specify relationships between tables and set various options on the relationship. Add the tables: Create the relationship: Decide if you’re going to set referential integrity: Decide if you want cascade upda…
Suggested Courses

600 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question