Showing posts with label import. Show all posts
Showing posts with label import. Show all posts

Friday, March 30, 2012

Problem running package

Hi,

I am trying to run simple import export package and if fails saying that pacage execution failed.

then i try using File system and the error say that it is not 32 bit driver and execution failed.


I get this error also

The return value was unknown. The process exit code was -1073741795. The step failed.


thanks

What does your package import/export? If you use 32-bit data providers, you will need to run your package in 32-bit mode.

Thanks.

Wednesday, March 28, 2012

Problem restoring a database from a .bak file

I'm provided with a .bak file that contains a backup of a small database. My question is how do I restore it to the SQL Server. I used the import feature but it gave me all kinds of errors when attempting to import it.
Any ideas!
thanks!
Hi,
You can either use SQL server enterprise manager GUI to restore a database
ot use the Query analyzer ... RESTORE database command.
Enterprise manager
1. Open Enterprise manager -- connect to SQL server -- Right click above the
database -- All tasks -- CLick Restore database
2. In the Restore database as "Give a Database name"
3. IN the restore options choose "From Device"
4. Click select devices command button -- CLick add and choose the backup
file name (.BAK file)
5. Click OK
6. IN restore screen also CLICK OK
-- This will restore the database
From Query Analyzer:-
1. Login to Query Analyzer as 'SA' or user with sysadmin ort equalent server
roles.
2. Execute the below command
Restore database <dbname> from disk='d:\backup\dbname.bak' with stats=10
-- Change the directory and file name based on ur requierement.
Thanks
Hari
MCDBA
"sbinev" <sbinev@.discussions.microsoft.com> wrote in message
news:14AACC0D-9E5A-45E6-ABC1-15623DA32CD6@.microsoft.com...
> I'm provided with a .bak file that contains a backup of a small database.
My question is how do I restore it to the SQL Server. I used the import
feature but it gave me all kinds of errors when attempting to import it.
> Any ideas!
> thanks!
|||sbinev,
SQL Server Books Online (BOL) installs with SQL Server. I heartily
recommend you look here for how to restore a database. The documentation
is very clear and comprehensive and shows you many methods of
accomplishing this task.
Mark Allison, SQL Server MVP
http://www.markallison.co.uk
Looking for a SQL Server replication book?
http://www.nwsu.com/0974973602.html
sbinev wrote:
> I'm provided with a .bak file that contains a backup of a small database. My question is how do I restore it to the SQL Server. I used the import feature but it gave me all kinds of errors when attempting to import it.
> Any ideas!
> thanks!
|||Thanks a lot guys!! )
The first method from the Enterprise Manager kept giving me errors, but I used T-SQL looked in the books online and with MOVE TO clause after the RESTORE... clause it worked. So thanks for your advice. It's hard to be novice!
"Hari Prasad" wrote:

> Hi,
> You can either use SQL server enterprise manager GUI to restore a database
> ot use the Query analyzer ... RESTORE database command.
> Enterprise manager
> 1. Open Enterprise manager -- connect to SQL server -- Right click above the
> database -- All tasks -- CLick Restore database
> 2. In the Restore database as "Give a Database name"
> 3. IN the restore options choose "From Device"
> 4. Click select devices command button -- CLick add and choose the backup
> file name (.BAK file)
> 5. Click OK
> 6. IN restore screen also CLICK OK
> -- This will restore the database
>
> From Query Analyzer:-
> 1. Login to Query Analyzer as 'SA' or user with sysadmin ort equalent server
> roles.
> 2. Execute the below command
> Restore database <dbname> from disk='d:\backup\dbname.bak' with stats=10
> -- Change the directory and file name based on ur requierement.
>
> --
> Thanks
> Hari
> MCDBA
> "sbinev" <sbinev@.discussions.microsoft.com> wrote in message
> news:14AACC0D-9E5A-45E6-ABC1-15623DA32CD6@.microsoft.com...
> My question is how do I restore it to the SQL Server. I used the import
> feature but it gave me all kinds of errors when attempting to import it.
>
>
sql

Friday, March 23, 2012

Problem Reading .CSV file data from reporting services

Hi,

In our application we are using DTS to import data from .csv file. now they came up with a requirement to compare data in .csv is exact match with imported data in the table using a report.

i had hard time to implement this. we tried two options to do so..

1. reading .csv file with custom extensions and rendering it on report (problem is datasource file name was standard, where a i am planning to read it from a table).

2. We have a separate DTS to read data from .csv but when we are accessing it from reproting services i am getting "Multistep OLE DB access error".

Can some one guide me right way to implement my requirement.

Thanks,
-Geeks..Idea

You can use the XML rendering extension to output just the data in the report. then use an Integration Services (formerly DTS) package to compare the input and output data.

Hope that helps,

-Lukasz

Problem Reading .CSV file data from reporting services

Hi,

In our application we are using DTS to import data from .csv file. now they came up with a requirement to compare data in .csv is exact match with imported data in the table using a report.

i had hard time to implement this. we tried two options to do so..

1. reading .csv file with custom extensions and rendering it on report (problem is datasource file name was standard, where a i am planning to read it from a table).

2. We have a separate DTS to read data from .csv but when we are accessing it from reproting services i am getting "Multistep OLE DB access error".

Can some one guide me right way to implement my requirement.

Thanks,
-Geeks..Idea

You can use the XML rendering extension to output just the data in the report. then use an Integration Services (formerly DTS) package to compare the input and output data.

Hope that helps,

-Lukasz

Tuesday, March 20, 2012

Problem of unicity constraint in a data flow

Hi,

I'm trying to import data from an xml file into a table in my database and I have a problem of unicity constraint in my table.

Here is an example of the data flow in my file :

CITY LOCATION_ID CATALOG_SAISON

PARIS 12 S06

PARIS 12 S07

NEW YORK 15 S06

BERLIN 14 S08

The primary key in my destination table is the two first fields CITY/LOCATION_ID, so I would like to have only one CATALOG_SEASON per CITY/LOCATION_ID. That's why I want insert the following flow in my destination table:

CITY LOCATION_ID CATALOG_SAISON

PARIS 12 S06

NEW YORK 15 S06

BERLIN 14 S08

In Transact-SQL, I can do it easily with an agregation on CATALOG_SAISON field, using a max() function for example : SELECT CITY, LOCATION_ID, max(CATALOG_SAISON) FROM temp_table GROUP BY CITY, LOCATION_ID

In SSIS I would like to do the same with an agregation task but I can't use max() function with a string field. So I can't agregate this field and the only solution I have found now is to create a temporary table in my database to execute the sql request and retrieve data I need.

I'm sure there's a best solution in SSIS, could you help me?

Thanks

Regards

Arnaud Gervais.

Why do you say you can't use Max() function in SSIS against a non-numeric column? What is the error or result?

Did you look at the sort trasformation with the 'Remove rows with duplicate sortvalues' option marked?

|||

I have tried to use Max() function to aggregate my data but I can't do it on a string column. I only have choice between "group by", "count" or "count distinct" aggregation functions.

And I've found this information in msdn : http://msdn2.microsoft.com/en-US/library/ms138031.aspx : "... In contrast to the Transact-SQL MAX function, this operation can be used only with numeric, date, and time data types."

I've tried your solution and it works very fine, thank you very much, you solved my problem!

Arnaud.