Comments (5)
This is a shortcoming of pgreplay I hadn't been aware of.
Unfortunately there is nothing I can do about it.
In a query like this, the client would send data type information in the BIND message so that there is no ambiguity (otherwise you'd get just the same error).
But this information is not logged, and so pgreplay cannot replay it.
Unless you don't have a lot of these statements, it shouldn't be a big problem; all that happens is that you will have a slightly higher error count than in the original run.
I have added documentation about this to the README file.
from pgreplay.
Hi Luarenz,
I found a workaround for the issue.
Everything will work correctly if I replace in my example of the logged statement $1 + $2 with $1::nemeric + $2.
So, more general replacment is:
sed -i 's/(
Regards,
Yury
from pgreplay.
Hi Luarenz,
I found a workaround for the issue.
Everything will work correctly if I replace in my example of the logged statement $1 + $2 with $1::nemeric + $2.So, more general replacment is:
sed -i 's/(
$[0-9]+)( *[^,] *$ )/\1::numeric\2/g' postgres_log_file.csvRegards,
Yury
from pgreplay.
Yes, certainly – if you write the query in a way that it does not require the data type information, it will replay without an error.
That sed
command will certainly solve the problem if you have no other statements of the form $1 + $2
in your log. $1
could be a date
value...
Do you want to keep this issue open for a certain reason?
from pgreplay.
Ah! You are right! I forgot about date type. But I'm sure I can write more complex handler of postgres log if needed.
Many thanks for answers. You may close the issue.
Regards,
Yury
from pgreplay.
Related Issues (20)
- make install fails on Mac OS X HOT 5
- Unable to compile pgreplay on ubuntu 18.04 HOT 2
- pgreplay seems to have stopped suddenly when executing HOT 10
- Generating undo records by using pgreplay HOT 1
- pgreplay not working with RDS csvlog HOT 2
- Queries per second HOT 3
- Replay freezes, all queries stuck in ClientRead state. HOT 3
- replay and uuids HOT 1
- Will the program support pg11 onward? HOT 3
- Transaction Deadlocks on Replay HOT 7
- Invalid free on replaying server-side prepare "ROLLBACK; DEALLOCATE ALL". HOT 4
- Tests are failing after installation HOT 6
- First run always lags behind HOT 3
- connection to database failed for a specific session HOT 1
- Parsing line error HOT 12
- Upgrade from pg 12 to pg 14 HOT 2
- ./configure fails on pg15.0 HOT 2
- Opened connections HOT 2
- Will PQgetResult cause stat_stmt statistics errors? HOT 1
- docker build Fails with Error (from master, commit a2f7c113197ed5623b35f09bfc299aae971d56e8) HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from pgreplay.