473,395 Members | 1,623 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

Try to import a database with sql script file

I try to import the small database from this website:

https://postgrespro.com/docs/postgrespro/12/demodb-bookings-installation

in Postgresql. I tried the restore button and choosed the sql file but it fails with the message:

"pg_restore: Error: Input file is apparently a dump in text format. Please use psql".

Then I tried to run the sql command from the file in the sql query, but it fails with the message:

"invalid byte sequence for encoding "UTF8".

Does anybody know how I can import it? Thx in advance!
Mar 10 '22 #1
0 4475

Sign in to post your reply or Sign up for a free account.

Similar topics

0
by: adrian GREEMAN | last post by:
When I try to import a text file with new data for an existing table I get the error "1148 - the used command is not allowed with this MySQL version." I have tried with both PHPMyAdmin2.3 and...
2
by: jet | last post by:
Hi, Maybe this is an easy task, but I'm having a really hard time figuring out how to do this. I'm a complete newbie to SQL Server. I have a database dump file from MySQL that's in .sql...
2
by: Smitro | last post by:
Hi, I'm in the middle of writing a script to import a csv file into mySQL (as apart of a bigger project) I need to know what are the best steps to go from $_FILES to file(). Once the file...
4
by: Rnt6872 | last post by:
I need to import a .csv file into a firebird database. I am able to cnnect tothe databe using: Dim ds1 As New DataSet Dim SQLString As String = "insert into rdstype27...
14
by: mfrsousa | last post by:
hi there, i have a huge large text file (350.000 lines) that i want to import to a MS Acccess Database, of course i don't want to use Access, but do it with C#. i already have tried the...
1
by: looza | last post by:
Hi All, I have a bunch of shell script files that use a common shell script file that contains certain global variables that are declared and initialized or derived by some arithmatic. I have...
0
by: Edwin.Madari | last post by:
here is a working code snippet to read from MySQL db. python tutorial has examples of reading from files. put them together to do your task. ===================================================...
16
by: giandeo | last post by:
Hello everybody I am trying to import an excel file for days into MS SQL Server 2000, unfortunately, I cannot see a ray of hope till now. I have surfed the WEB for hours, but again no...
12
by: Miguel Valenzue | last post by:
I collect traffic data from a machine that outputs text files with the data. I want to import each text file as it's own table into an Access database and do it without having to run the import...
7
by: hvsummer | last post by:
After long time testing in my database, upgraded a lot of part from first code, I'm very happy to show everyone my Import/Link Excel vba code that can be very usefull and stable. Function (not sub...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.